package com.dd.cloud.user.entity.lock;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.gitee.sunchenbin.mybatis.actable.annotation.Column;
import com.gitee.sunchenbin.mybatis.actable.annotation.Table;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 
 * </p>
 *
 * @author czg
 * @since 2022-07-27
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@Table(comment = "分布式定时器")
public class Shedlock implements Serializable {

    private static final long serialVersionUID=1L;

    @TableId(value = "NAME", type = IdType.INPUT)
    @Column(isKey = true, isAutoIncrement = false)
    private String name;

    @Column(comment = "时间")
    private LocalDateTime lockUntil;

    @Column(comment = "时间")
    private LocalDateTime lockedAt;

    @Column(comment = "锁")
    private String lockedBy;


}
